<?php
$tabindex = 1;
?>

<table id='dnevnik_content' width="850px" border="1" cellpadding="0" cellspacing="0" style="border-collapse:collapse; empty-cells: show; border-color: #000;">
  <tr>
    <th scope="col" style="width: 30%;">Nastavni predmet</th>
    <th scope="col" style="width: 69%;">Domaći zadatak</th>
  </tr>
<?php
  foreach($predmets as $predmet_id => $predmet_naziv){?>
     <tr>
        <th scope="row" class="predmet_naziv"><?php echo $predmet_naziv ?></th>
        <td style="text-align:center; padding: 1px 3px;"><input style="width: 99%;" maxlength="200" type="text" class="input_domaci" id="do_<?php echo $predmet_id ?>" tabindex="<?php echo $tabindex++ ?>" /></td>
     </tr>
<?php }?>
</table>

<div style="text-align:left; margin-left: 380px; padding-top: 5px;">
  <a id="dugme" onclick="domaciUnos();" href="javascript: void(0)" class="button"><span>Unesi</span></a>
  <span id="complete"></span>
</div>